// --------------------------------------------------------------------------------------------
// Version: MPL 1.1/GPL 2.0/LGPL 2.1
// 
// The contents of this file are subject to the Mozilla Public License Version
// 1.1 (the "License"); you may not use this file except in compliance with
// the License. You may obtain a copy of the License at
// http://www.mozilla.org/MPL/
// 
// Software distributed under the License is distributed on an "AS IS" basis,
// WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
// for the specific language governing rights and limitations under the
// License.
// 
// <remarks>
// Generated by IDLImporter from file nsIURLFormatter.idl
// 
// You should use these interfaces when you access the COM objects defined in the mentioned
// IDL/IDH file.
// </remarks>
// --------------------------------------------------------------------------------------------
namespace Gecko
{
	using System;
	using System.Runtime.InteropServices;
	using System.Runtime.InteropServices.ComTypes;
	using System.Runtime.CompilerServices;
	
	
	/// <summary>
    /// nsIURLFormatter
    ///
    /// nsIURLFormatter exposes methods to substitute variables in URL formats.
    /// Variable names can contain 'A-Z' letters and '_' characters.
    ///
    /// Mozilla Applications linking to Mozilla websites are strongly encouraged to use
    /// URLs of the following format:
    ///
    /// http[s]://%SERVICE%.mozilla.[com|org]/%LOCALE%/
    /// </summary>
	[ComImport()]
	[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
	[Guid("4ab31d30-372d-11db-a98b-0800200c9a66")]
	public interface nsIURLFormatter
	{
		
		/// <summary>
        /// formatURL - Formats a string URL
        ///
        /// The set of known variables is predefined.
        /// If a variable is unknown, it is left unchanged and a non-fatal error is reported.
        ///
        /// @param aFormat string Unformatted URL.
        ///
        /// @return The formatted URL.
        /// </summary>
		[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType=MethodCodeType.Runtime)]
		void FormatURL([MarshalAs(UnmanagedType.CustomMarshaler, MarshalType = "Gecko.CustomMarshalers.AStringMarshaler")] nsAStringBase aFormat, [MarshalAs(UnmanagedType.CustomMarshaler, MarshalType = "Gecko.CustomMarshalers.AStringMarshaler")] nsAStringBase retval);
		
		/// <summary>
        /// formatURLPref - Formats a string URL stored in a preference
        ///
        /// If the preference value cannot be retrieved, a fatal error is reported
        /// and the "about:blank" URL is returned.
        ///
        /// @param aPref string Preference name.
        ///
        /// @return The formatted URL returned by formatURL(), or "about:blank".
        /// </summary>
		[MethodImpl(MethodImplOptions.InternalCall, MethodCodeType=MethodCodeType.Runtime)]
		void FormatURLPref([MarshalAs(UnmanagedType.CustomMarshaler, MarshalType = "Gecko.CustomMarshalers.AStringMarshaler")] nsAStringBase aPref, [MarshalAs(UnmanagedType.CustomMarshaler, MarshalType = "Gecko.CustomMarshalers.AStringMarshaler")] nsAStringBase retval);
	}
}
